package cn.yoyo.service;

import cn.yoyo.dao.LargefileDao;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.web.multipart.MultipartFile;

import java.io.IOException;
import java.io.InputStream;

@Service
public class LargefileServiceImpl implements LargefileService{
    @Autowired
    LargefileDao largefileDao;
    @Override
    public String saveMultipartFile(MultipartFile file) throws Exception {
        return largefileDao.saveMultipartFile(file);
    }

    @Override
    public InputStream getInpuStreamById(String id) throws IOException {
        return largefileDao.getInpuStreamById(id);
    }
}
